package com.rzl.expense.expense.service.impl;

import java.util.List;
import com.rzl.expense.common.utils.DateUtils;
import org.apache.ibatis.annotations.Param;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.rzl.expense.expense.mapper.EleContractbillaccountMapper;
import com.rzl.expense.expense.domain.EleContractbillaccount;
import com.rzl.expense.expense.service.IEleContractbillaccountService;

/**
 * 电费合同报账点关系Service业务层处理
 * 
 * @author expense
 * @date 2025-03-06
 */
@Service
public class EleContractbillaccountServiceImpl implements IEleContractbillaccountService 
{
    @Autowired
    private EleContractbillaccountMapper eleContractbillaccountMapper;

    /**
     * 查询电费合同报账点关系
     * 
     * @param elebillaccountcontractId 电费合同报账点关系主键
     * @return 电费合同报账点关系
     */
    @Override
    public EleContractbillaccount selectEleContractbillaccountByElebillaccountcontractId(String elebillaccountcontractId)
    {
        return eleContractbillaccountMapper.selectEleContractbillaccountByElebillaccountcontractId(elebillaccountcontractId);
    }

    /**
     * 查询电费合同报账点关系列表
     * 
     * @param eleContractbillaccount 电费合同报账点关系
     * @return 电费合同报账点关系
     */
    @Override
    public List<EleContractbillaccount> selectEleContractbillaccountList(EleContractbillaccount eleContractbillaccount)
    {
        return eleContractbillaccountMapper.selectEleContractbillaccountList(eleContractbillaccount);
    }

    /**
     * 新增电费合同报账点关系
     * 
     * @param eleContractbillaccount 电费合同报账点关系
     * @return 结果
     */
    @Override
    public int insertEleContractbillaccount(EleContractbillaccount eleContractbillaccount)
    {
        return eleContractbillaccountMapper.insertEleContractbillaccount(eleContractbillaccount);
    }

    /**
     * 修改电费合同报账点关系
     * 
     * @param eleContractbillaccount 电费合同报账点关系
     * @return 结果
     */
    @Override
    public int updateEleContractbillaccount(EleContractbillaccount eleContractbillaccount)
    {
        eleContractbillaccount.setUpdateTime(DateUtils.getNowDate());
        return eleContractbillaccountMapper.updateEleContractbillaccount(eleContractbillaccount);
    }

    /**
     * 批量删除电费合同报账点关系
     * 
     * @param elebillaccountcontractIds 需要删除的电费合同报账点关系主键
     * @return 结果
     */
    @Override
    public int deleteEleContractbillaccountByElebillaccountcontractIds(String[] elebillaccountcontractIds)
    {
        return eleContractbillaccountMapper.deleteEleContractbillaccountByElebillaccountcontractIds(elebillaccountcontractIds);
    }

    /**
     * 删除电费合同报账点关系信息
     * 
     * @param elebillaccountcontractId 电费合同报账点关系主键
     * @return 结果
     */
    @Override
    public int deleteEleContractbillaccount(String startDate, String endDate)
    {
        return eleContractbillaccountMapper.deleteEleContractbillaccount(startDate,endDate);
    }




    @Override
    public void batchEleContractbillaccount(List<EleContractbillaccount> list)
    {

         eleContractbillaccountMapper.batchEleContractbillaccount(list);
    }


}
